package com.linkhub.oms.data.sync.service;

import com.linkhub.oms.data.sync.api.shopify.domain.response.ShopOrderResponse;
import com.linkhub.oms.entity.ShopEntity;

import java.util.List;

/**
 * @Description: ShopifyDataSyncBizService
 * @Author: echo
 * @Date: 2024/3/23 09:45
 * @Version: 1.0
 */
public interface ShopifyDataSyncBizService {


    /**
     * 同步商店商品数据, 一个商店一个事务
     *
     * @param shopEntity shopEntity
     * @return 同步数量
     */
    Integer syncShopProducts(ShopEntity shopEntity);


    /**
     * 同步所有已授权的商店商品
     */
    void syncAllShopProducts();

    /**
     * 同步所有已授权的商店运费名称
     */
    void syncAllShopShippingName();

    /**
     * 异步拉取商店商品信息
     *
     * @param shopEntity shopEntity
     */
    void asyncPullShopProducts(ShopEntity shopEntity);

    void batchAsyncPullShopProducts( List<ShopEntity> shops );

    /**
     * 同步所有已授权的商店订单
     */
    void syncAllShopOrders();

    /**
     * 异步拉取商店订单信息
     *
     * @param shopEntity shopEntity
     */
    void asyncPullShopOrders(ShopEntity shopEntity);


    /**
     * 同步商店订单, 一个商店一个事务
     *
     * @param shopEntity shopEntity
     * @return ShopOrderResponse
     */
    ShopOrderResponse syncShopOrders(ShopEntity shopEntity);

    void asyncPullShopShippingName(ShopEntity shop);

    void syncShopShippingName(ShopEntity shopEntity);
}
